start: 00000000 4E56 FFFC link A6, -0x0004 00000004 48E7 0730 movem.l -[A7], D5,D6,D7,A2,A3 00000008 266E 000E movea.l A3, [A6 + 0xE] 0000000C 200B move.l D0, A3 0000000E 6608 bne +0xA /* 00000018 */ 00000010 42AE 0014 clr.l [A6 + 0x14] 00000014 6000 01A0 bra +0x1A2 /* 000001B6 */ label00000018: 00000018 2453 movea.l A2, [A3] 0000001A 200A move.l D0, A2 0000001C 6608 bne +0xA /* 00000026 */ 0000001E 42AE 0014 clr.l [A6 + 0x14] 00000022 6000 0192 bra +0x194 /* 000001B6 */ label00000026: 00000026 302E 000C move.w D0, [A6 + 0xC] 0000002A 0C40 0008 cmpi.w D0, 0x8 0000002E 6200 0182 bhi +0x184 /* 000001B2 */ 00000032 43FA 0198 lea.l A1, [PC + 0x198 /* 000001CC, value 0xFEC0FF92 */] 00000036 D040 add.w D0, D0 00000038 D2F1 0000 add.w A1, [A1 + D0.w] 0000003C 4ED1 jmp [A1] 0000003E 70FF moveq.l D0, 0xFFFFFFFF 00000040 2540 001C move.l [A2 + 0x1C], D0 00000044 4267 clr.w -[A7] 00000046 2F3C 7164 2020 move.l -[A7], 0x71642020 /* 'qd ' */ 0000004C 486E 0008 pea.l [A6 + 0x8] 00000050 4EBA 018C jsr [PC + 0x18C /* 000001DE */] 00000054 4A5F tst.w [A7]+ 00000056 6D00 015A blt +0x15C /* 000001B2 */ 0000005A 0CAE 0000 0100 0008 cmpi.l [A6 + 0x8], 0x100 00000062 6D00 014E blt +0x150 /* 000001B2 */ 00000066 2053 movea.l A0, [A3] 00000068 42A8 001C clr.l [A0 + 0x1C] 0000006C 6000 0144 bra +0x146 /* 000001B2 */ 00000070 2E2A 001C move.l D7, [A2 + 0x1C] 00000074 70FF moveq.l D0, 0xFFFFFFFF 00000076 B087 cmp.l D0, D7 00000078 6700 0138 beq +0x13A /* 000001B2 */ 0000007C 4A87 tst.l D7 0000007E 6700 0132 beq +0x134 /* 000001B2 */ 00000082 2F2A 001C move.l -[A7], [A2 + 0x1C] 00000086 AA25 syscall DisposeCIcon/DisposCIcon 00000088 6000 0128 bra +0x12A /* 000001B2 */ 0000008C 4A2A 0010 tst.b [A2 + 0x10] 00000090 6700 0120 beq +0x122 /* 000001B2 */ 00000094 4A2A 0011 tst.b [A2 + 0x11] 00000098 6706 beq +0x8 /* 000000A0 */ 0000009A 302A 0016 move.w D0, [A2 + 0x16] 0000009E 6004 bra +0x6 /* 000000A4 */ label000000A0: 000000A0 302A 0014 move.w D0, [A2 + 0x14] label000000A4: 000000A4 3C00 move.w D6, D0 000000A6 2E2A 001C move.l D7, [A2 + 0x1C] 000000AA 70FF moveq.l D0, 0xFFFFFFFF 000000AC B087 cmp.l D0, D7 000000AE 666A bne +0x6C /* 0000011A */ 000000B0 42A7 clr.l -[A7] 000000B2 2F3C 6369 636E move.l -[A7], 0x6369636E /* 'cicn' */ 000000B8 3F06 move.w -[A7], D6 000000BA A9A0 syscall GetResource 000000BC 2E1F move.l D7, [A7]+ 000000BE 2453 movea.l A2, [A3] 000000C0 4A87 tst.l D7 000000C2 674E beq +0x50 /* 00000112 */ 000000C4 2047 movea.l A0, D7 000000C6 2650 movea.l A3, [A0] 000000C8 200B move.l D0, A3 000000CA 6746 beq +0x48 /* 00000112 */ 000000CC 41EB 0052 lea.l A0, [A3 + 0x52] 000000D0 2748 0032 move.l [A3 + 0x32], A0 000000D4 7A38 moveq.l D5, 0x38 000000D6 DA8B add.l D5, A3 000000D8 2045 movea.l A0, D5 000000DA 2245 movea.l A1, D5 000000DC 3029 0004 move.w D0, [A1 + 0x4] 000000E0 9050 sub.w D0, [A0] 000000E2 C1EB 0036 muls.w D0, [A3 + 0x36] 000000E6 D0AB 0032 add.l D0, [A3 + 0x32] 000000EA 2740 0040 move.l [A3 + 0x40], D0 000000EE 2047 movea.l A0, D7 000000F0 A029 syscall HLock 000000F2 486B 0040 pea.l [A3 + 0x40] 000000F6 486B 0032 pea.l [A3 + 0x32] 000000FA 206A 0004 movea.l A0, [A2 + 0x4] 000000FE 4868 0002 pea.l [A0 + 0x2] 00000102 486B 0046 pea.l [A3 + 0x46] 00000106 2F05 move.l -[A7], D5 00000108 486A 0008 pea.l [A2 + 0x8] 0000010C A817 syscall CopyMask 0000010E 2047 movea.l A0, D7 00000110 A02A syscall HUnlock label00000112: 00000112 42AE 0014 clr.l [A6 + 0x14] 00000116 6000 009E bra +0xA0 /* 000001B6 */ label0000011A: 0000011A BC6A 0012 cmp.w D6, [A2 + 0x12] 0000011E 6710 beq +0x12 /* 00000130 */ 00000120 4A87 tst.l D7 00000122 670C beq +0xE /* 00000130 */ 00000124 2F2A 001C move.l -[A7], [A2 + 0x1C] 00000128 AA25 syscall DisposeCIcon/DisposCIcon 0000012A 2453 movea.l A2, [A3] 0000012C 42AA 001C clr.l [A2 + 0x1C] label00000130: 00000130 4AAA 001C tst.l [A2 + 0x1C] 00000134 6612 bne +0x14 /* 00000148 */ 00000136 42A7 clr.l -[A7] 00000138 3F06 move.w -[A7], D6 0000013A AA1E syscall GetCIcon 0000013C 2E1F move.l D7, [A7]+ 0000013E 2453 movea.l A2, [A3] 00000140 2547 001C move.l [A2 + 0x1C], D7 00000144 3546 0012 move.w [A2 + 0x12], D6 label00000148: 00000148 4AAA 001C tst.l [A2 + 0x1C] 0000014C 670A beq +0xC /* 00000158 */ 0000014E 486A 0008 pea.l [A2 + 0x8] 00000152 2F2A 001C move.l -[A7], [A2 + 0x1C] 00000156 AA1F syscall PlotCIcon label00000158: 00000158 42AE 0014 clr.l [A6 + 0x14] 0000015C 6058 bra +0x5A /* 000001B6 */ 0000015E 0C2A 00FF 0011 cmpi.b [A2 + 0x11], 0xFF 00000164 6606 bne +0x8 /* 0000016C */ 00000166 42AE 0014 clr.l [A6 + 0x14] 0000016A 604A bra +0x4C /* 000001B6 */ label0000016C: 0000016C 4267 clr.w -[A7] 0000016E 2F2E 0008 move.l -[A7], [A6 + 0x8] 00000172 A86A syscall HiWord 00000174 3D5F FFFC move.w [A6 - 0x4], [A7]+ 00000178 4267 clr.w -[A7] 0000017A 2F2E 0008 move.l -[A7], [A6 + 0x8] 0000017E A86B syscall LoWord 00000180 3D5F FFFE move.w [A6 - 0x2], [A7]+ 00000184 4227 clr.b -[A7] 00000186 2F2E FFFC move.l -[A7], [A6 - 0x4] 0000018A 486A 0008 pea.l [A2 + 0x8] 0000018E A8AD syscall PtInRect 00000190 4A1F tst.b [A7]+ 00000192 6708 beq +0xA /* 0000019C */ 00000194 700A moveq.l D0, 0x0A 00000196 2D40 0014 move.l [A6 + 0x14], D0 0000019A 601A bra +0x1C /* 000001B6 */ label0000019C: 0000019C 42AE 0014 clr.l [A6 + 0x14] 000001A0 6014 bra +0x16 /* 000001B6 */ 000001A2 42A7 clr.l -[A7] 000001A4 2F2E 0008 move.l -[A7], [A6 + 0x8] 000001A8 4EBA 0242 jsr [PC + 0x242 /* 000003EC */] 000001AC 486A 0008 pea.l [A2 + 0x8] 000001B0 A8DF syscall RectRgn label000001B2: 000001B2 42AE 0014 clr.l [A6 + 0x14] label000001B6: 000001B6 4CDF 0CE0 movem.l D5,D6,D7,A2,A3, [A7]+ 000001BA 4E5E unlink A6 000001BC 205F movea.l A0, [A7]+ 000001BE 4FEF 000C lea.l A7, [A7 + 0xC] 000001C2 4ED0 jmp [A0] 000001C4 846D 6169 or.w D2, [A5 + 0x6169] 000001C8 6E00 0012 bgt +0x14 /* 000001DC */ 000001CC FEC0 .extension 0xEC0 // unimplemented 000001CE FF92 .extension 0xF92 // unimplemented 000001D0 FFD6 .extension 0xFD6 // unimplemented 000001D2 FE72 .extension 0xE72 // unimplemented 000001D4 FEA4 .extension 0xEA4 // unimplemented 000001D6 FFE6 .extension 0xFE6 // unimplemented 000001D8 FFE6 .extension 0xFE6 // unimplemented 000001DA FFE6 .extension 0xFE6 // unimplemented label000001DC: 000001DC FFE6 .extension 0xFE6 // unimplemented fn000001DE: 000001DE 4E56 0000 link A6, 0 000001E2 203C 0000 A89F move.l D0, 0xA89F 000001E8 A746 syscall GetToolBoxTrapAddress/GetToolTrapAddress, flags=7 000001EA 2F08 move.l -[A7], A0 000001EC 203C 0000 A0AD move.l D0, 0xA0AD 000001F2 A346 syscall GetOSTrapAddress, flags=3 000001F4 B1DF cmpa.l A0, [A7]+ 000001F6 670E beq +0x10 /* 00000206 */ 000001F8 202E 000C move.l D0, [A6 + 0xC] 000001FC A1AD syscall Gestalt, flags=1 000001FE 226E 0008 movea.l A1, [A6 + 0x8] 00000202 2288 move.l [A1], A0 00000204 6026 bra +0x28 /* 0000022C */ label00000206: 00000206 41FA 0036 lea.l A0, [PC + 0x36 /* 0000023E, value 0x76657273 'vers' */] 0000020A 303C EA51 move.w D0, 0xEA51 0000020E 222E 000C move.l D1, [A6 + 0xC] label00000212: 00000212 B298 cmp.l D1, [A0]+ 00000214 6706 beq +0x8 /* 0000021C */ 00000216 4A98 tst.l [A0]+ 00000218 6712 beq +0x14 /* 0000022C */ 0000021A 60F6 bra -0x8 /* 00000212 */ label0000021C: 0000021C 43FA 0020 lea.l A1, [PC + 0x20 /* 0000023E, value 0x76657273 'vers' */] 00000220 D3D0 add.l A1, [A0] 00000222 4ED1 jmp [A1] label00000224: 00000224 226E 0008 movea.l A1, [A6 + 0x8] 00000228 2280 move.l [A1], D0 0000022A 4240 clr.w D0 label0000022C: 0000022C 3D40 0010 move.w [A6 + 0x10], D0 00000230 4E5E unlink A6 00000232 205F movea.l A0, [A7]+ 00000234 508F addq.l A7, 8 00000236 4ED0 jmp [A0] label00000238: 00000238 303C EA52 move.w D0, 0xEA52 0000023C 60EE bra -0x10 /* 0000022C */ 0000023E 7665 moveq.l D3, 0x65 00000240 7273 moveq.l D1, 0x73 00000242 0000 0060 ori.b D0, 0x60 /* '`' */ 00000246 6D61 blt +0x63 /* 000002A9 */ 00000248 6368 bls +0x6A /* 000002B2 */ 0000024A 0000 0064 ori.b D0, 0x64 /* 'd' */ 0000024E 7379 moveq.l D1, 0x79 00000250 7376 moveq.l D1, 0x76 00000252 0000 0088 ori.b D0, 0x88 00000256 7072 moveq.l D0, 0x72 00000258 6F63 ble +0x65 /* 000002BD */ 0000025A 0000 0092 ori.b D0, 0x92 0000025E 6670 bne +0x72 /* 000002D0 */ 00000260 7520 moveq.l D2, 0x20 00000262 0000 009E ori.b D0, 0x9E 00000266 7164 moveq.l D0, 0x64 00000268 2020 move.l D0, -[A0] 0000026A 0000 00E8 ori.b D0, 0xE8 0000026E 6B62 bmi +0x64 /* 000002D2 */ 00000270 6420 bcc +0x22 /* 00000292 */ 00000272 0000 011A ori.b D0, 0x1A 00000276 6174 bsr +0x76 /* 000002EC */ 00000278 6C6B bge +0x6D /* 000002E5 */ 0000027A 0000 0142 ori.b D0, 0x42 /* 'B' */ 0000027E 6D6D blt +0x6F /* 000002ED */ 00000280 7520 moveq.l D2, 0x20 00000282 0000 0164 ori.b D0, 0x64 /* 'd' */ 00000286 7261 moveq.l D1, 0x61 00000288 6D20 blt +0x22 /* 000002AA */ 0000028A 0000 0188 ori.b D0, 0x88 0000028E 6C72 bge +0x74 /* 00000302 */ 00000290 616D bsr +0x6F /* 000002FF */ label00000292: 00000292 0000 0188 ori.b D0, 0x88 00000296 0000 0000 ori.b D0, 0x0 0000029A 0000 0000 ori.b D0, 0x0 0000029E 7001 moveq.l D0, 0x01 000002A0 6082 bra -0x7C /* 00000224 */ 000002A2 2278 02AE movea.l A1, [0x000002AE /* ROMBase */] 000002A6 7004 moveq.l D0, 0x04 000002A8 0C69 0075 0008 cmpi.w [A1 + 0x8], 0x75 /* 'u' */ // begin alternate branch 000002AA-000002B2 label000002AA: 000002AA 0075 0008 6712 0C69 ori.w [[A5 + D6 * 8] + 0xC69], 0x8 // end alternate branch 000002AA-000002B2 label000002AA: // (misaligned) 000002AE 6712 beq +0x14 /* 000002C2 */ 000002B0 0C69 0276 0008 cmpi.w [A1 + 0x8], 0x276 // begin alternate branch 000002B2-000002B8 label000002B2: 000002B2 0276 0008 6604 andi.w [A6 + D6.w * 8 + 0x4], 0x8 // end alternate branch 000002B2-000002B8 label000002B2: // (misaligned) 000002B6 6604 bne +0x6 /* 000002BC */ 000002B8 5240 addq.w D0, 1 000002BA 6006 bra +0x8 /* 000002C2 */ label000002BC: 000002BC 1038 0CB3 move.b D0, [0x00000CB3 /* MMUFluff/MachineType */] 000002C0 5C80 addq.l D0, 6 label000002C2: 000002C2 6000 FF60 bra -0x9E /* 00000224 */ 000002C6 7000 moveq.l D0, 0x00 000002C8 3038 015A move.w D0, [0x0000015A /* SysVersion */] 000002CC 6000 FF56 bra -0xA8 /* 00000224 */ label000002D0: 000002D0 7000 moveq.l D0, 0x00 label000002D2: 000002D2 1038 012F move.b D0, [0x0000012F /* CPUFlag */] 000002D6 5240 addq.w D0, 1 000002D8 6000 FF4A bra -0xB4 /* 00000224 */ 000002DC 0C38 0004 012F cmpi.b [0x0000012F /* CPUFlag */], 0x4 000002E2 6738 beq +0x3A /* 0000031C */ 000002E4 0838 0004 0B22 btst.b [0x00000B22 /* HWCfgFlags */], 0x4 000002EA 6734 beq +0x36 /* 00000320 */ fn000002EC: 000002EC 204F movea.l A0, A7 000002EE F280 .extension 0x280 // unimplemented 000002F0 0000 F327 ori.b D0, 0x27 /* '\'' */ 000002F4 3017 move.w D0, [A7] 000002F6 2E48 movea.l A7, A0 000002F8 0C40 1F18 cmpi.w D0, 0x1F18 000002FC 6716 beq +0x18 /* 00000314 */ 000002FE 0C40 3F18 cmpi.w D0, 0x3F18 label00000302: 00000302 6710 beq +0x12 /* 00000314 */ 00000304 0C40 3F38 cmpi.w D0, 0x3F38 /* '?8' */ 00000308 670E beq +0x10 /* 00000318 */ 0000030A 0C40 1F38 cmpi.w D0, 0x1F38 0000030E 6708 beq +0xA /* 00000318 */ 00000310 7000 moveq.l D0, 0x00 00000312 600E bra +0x10 /* 00000322 */ label00000314: 00000314 7001 moveq.l D0, 0x01 00000316 600A bra +0xC /* 00000322 */ label00000318: 00000318 7002 moveq.l D0, 0x02 0000031A 6006 bra +0x8 /* 00000322 */ label0000031C: 0000031C 7003 moveq.l D0, 0x03 0000031E 6002 bra +0x4 /* 00000322 */ label00000320: 00000320 7000 moveq.l D0, 0x00 label00000322: 00000322 6000 FF00 bra -0xFE /* 00000224 */ 00000326 0C78 3FFF 028E cmpi.w [0x0000028E /* ROM85 */], 0x3FFF 0000032C 6E1C bgt +0x1E /* 0000034A */ 0000032E 303C A89F move.w D0, 0xA89F 00000332 A746 syscall GetToolBoxTrapAddress/GetToolTrapAddress, flags=7 00000334 2408 move.l D2, A0 00000336 203C 0000 AB03 move.l D0, 0xAB03 0000033C A746 syscall GetToolBoxTrapAddress/GetToolTrapAddress, flags=7 0000033E 203C 0000 0100 move.l D0, 0x100 00000344 B488 cmp.l D2, A0 00000346 6606 bne +0x8 /* 0000034E */ 00000348 600A bra +0xC /* 00000354 */ label0000034A: 0000034A 7000 moveq.l D0, 0x00 0000034C 6006 bra +0x8 /* 00000354 */ label0000034E: 0000034E 203C 0000 0200 move.l D0, 0x200 label00000354: 00000354 6000 FECE bra -0x130 /* 00000224 */ 00000358 1038 021E move.b D0, [0x0000021E /* KbdType */] 0000035C 41FA 0016 lea.l A0, [PC + 0x16 /* 00000374, value 0x3130B02 */] 00000360 2248 movea.l A1, A0 label00000362: 00000362 1218 move.b D1, [A0]+ 00000364 6700 FED2 beq -0x12C /* 00000238 */ 00000368 B200 cmp.b D1, D0 0000036A 66F6 bne -0x8 /* 00000362 */ 0000036C 91C9 sub.l A0, A1 0000036E 2008 move.l D0, A0 00000370 6000 FEB2 bra -0x14C /* 00000224 */ 00000374 0313 btst [A3], D1 00000376 0B02 btst D2, D5 00000378 0106 btst D6, D0 0000037A 0704 btst D4, D3 0000037C 0508 btst A0, D2 0000037E 0900 btst D0, D4 00000380 7000 moveq.l D0, 0x00 00000382 4A38 0291 tst.b [0x00000291 /* PortBUse */] 00000386 6B16 bmi +0x18 /* 0000039E */ 00000388 1238 01FB move.b D1, [0x000001FB /* SPConfig */] 0000038C 0201 000F andi.b D1, 0xF 00000390 0C01 0001 cmpi.b D1, 0x1 00000394 6608 bne +0xA /* 0000039E */ 00000396 2078 02DC movea.l A0, [0x000002DC /* ABusDCE */] 0000039A 1028 0007 move.b D0, [A0 + 0x7] label0000039E: 0000039E 6000 FE84 bra -0x17A /* 00000224 */ 000003A2 0C38 0002 012F cmpi.b [0x0000012F /* CPUFlag */], 0x2 000003A8 6D16 blt +0x18 /* 000003C0 */ 000003AA 7000 moveq.l D0, 0x00 000003AC 1038 0CB1 move.b D0, [0x00000CB1 /* MMUType */] 000003B0 0C00 0001 cmpi.b D0, 0x1 000003B4 670C beq +0xE /* 000003C2 */ 000003B6 0C00 0003 cmpi.b D0, 0x3 000003BA 6D04 blt +0x6 /* 000003C0 */ 000003BC 5340 subq.w D0, 1 000003BE 6002 bra +0x4 /* 000003C2 */ label000003C0: 000003C0 7000 moveq.l D0, 0x00 label000003C2: 000003C2 6000 FE60 bra -0x19E /* 00000224 */ 000003C6 303C A89F move.w D0, 0xA89F 000003CA A746 syscall GetToolBoxTrapAddress/GetToolTrapAddress, flags=7 000003CC 2408 move.l D2, A0 000003CE 203C 0000 A88F move.l D0, 0xA88F 000003D4 A746 syscall GetToolBoxTrapAddress/GetToolTrapAddress, flags=7 000003D6 2038 0108 move.l D0, [0x00000108 /* MemTop */] 000003DA B488 cmp.l D2, A0 000003DC 670A beq +0xC /* 000003E8 */ 000003DE 598F subq.l A7, 4 000003E0 3F3C 0016 move.w -[A7], 0x16 000003E4 A88F syscall OSDispatch 000003E6 201F move.l D0, [A7]+ label000003E8: 000003E8 6000 FE3A bra -0x1C4 /* 00000224 */ fn000003EC: 000003EC 225F movea.l A1, [A7]+ 000003EE 201F move.l D0, [A7]+ 000003F0 0838 0006 028E btst.b [0x0000028E /* ROM85 */], 0x6 000003F6 6606 bne +0x8 /* 000003FE */ 000003F8 A055 syscall StripAddress 000003FA 2E80 move.l [A7], D0 000003FC 4ED1 jmp [A1] label000003FE: 000003FE C0B8 031A and.l D0, [0x0000031A /* MaskBC/MaskHandle/MaskPtr/Lo3Bytes */] 00000402 2E80 move.l [A7], D0 00000404 4ED1 jmp [A1]